visualize_MMs <- function(.data) {
  mmeans <- .data %>%
    pivot_longer(
      cols = c(Name, Gender, Education, Experience, Screening),
      names_to = "attribute",
      values_to = "level"
    ) %>%
    group_by(experiment, attribute, level) %>%
    reframe(tidy(lm_robust(selected ~ 1, data = pick(everything())))) %>%
    mutate(
      significnat = case_when(conf.low < 0.5 & conf.high < 0.5 ~ TRUE,
        conf.low > 0.5 & conf.high > 0.5 ~ TRUE,
        .default = FALSE
      ),
      attribute = fct_relevel(factor(attribute), c("Name", "Gender"))
    )

  ggplot(mmeans) +
    geom_vline(
      xintercept = 0.5,
      linetype = "dashed",
      color = "gray"
    ) +
    geom_pointrange(aes(
      x = estimate,
      xmin = conf.low,
      xmax = conf.high,
      color = significnat,
      y = level
    )) +
    facet_grid(attribute ~ experiment, scales = "free_y", space = "free") +
    scale_color_colorblind() +
    guides(color = "none") +
    theme_few() +
    coord_cartesian(xlim = c(0.2, 0.8)) +
    labs(
      y = NULL,
      x = "Marginal Mean"
    )
}
